package com.ruoyi.system.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.system.mapper.PhotoMapper;
import com.ruoyi.system.domain.Photo;
import com.ruoyi.system.service.IPhotoService;

/**
 * 图片标注Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-06-04
 */
@Service
public class PhotoServiceImpl implements IPhotoService 
{
    @Autowired
    private PhotoMapper photoMapper;

    /**
     * 查询图片标注
     * 
     * @param photoId 图片标注主键
     * @return 图片标注
     */
    @Override
    public Photo selectPhotoByPhotoId(Long photoId)
    {
        return photoMapper.selectPhotoByPhotoId(photoId);
    }

    /**
     * 查询图片标注列表
     * 
     * @param photo 图片标注
     * @return 图片标注
     */
    @Override
    public List<Photo> selectPhotoList(Photo photo)
    {
        return photoMapper.selectPhotoList(photo);
    }

    /**
     * 新增图片标注
     * 
     * @param photo 图片标注
     * @return 结果
     */
    @Override
    public int insertPhoto(Photo photo)
    {
        return photoMapper.insertPhoto(photo);
    }

    /**
     * 修改图片标注
     * 
     * @param photo 图片标注
     * @return 结果
     */
    @Override
    public int updatePhoto(Photo photo)
    {
        return photoMapper.updatePhoto(photo);
    }

    /**
     * 批量删除图片标注
     * 
     * @param photoIds 需要删除的图片标注主键
     * @return 结果
     */
    @Override
    public int deletePhotoByPhotoIds(Long[] photoIds)
    {
        return photoMapper.deletePhotoByPhotoIds(photoIds);
    }

    /**
     * 删除图片标注信息
     * 
     * @param photoId 图片标注主键
     * @return 结果
     */
    @Override
    public int deletePhotoByPhotoId(Long photoId)
    {
        return photoMapper.deletePhotoByPhotoId(photoId);
    }
}
